package com.baiwei.vpnapi.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.annotation.JsonIgnore;
import lombok.Data;
import org.springframework.data.annotation.Id;

import java.util.Date;

/**
 * @program: vpnapi
 * @description: 推送消息实体
 * @author: Mr. Stone
 * @create: 2020-03-16 15:13
 **/
@TableName("push_msg")
@Data
public class VpnMessage {
    @TableId(value="id", type=IdType.AUTO)
    private Integer id;
    private String title;
    private String content;
    @JsonIgnore
    private Integer category;
    @JsonIgnore
    private Date createTime;
    @JsonFormat(pattern="yyyy-MM-dd",timezone="GMT+8")
    private Date sendTime;
    @JsonIgnore
    private Date updateTime;
    @JsonIgnore
    private Integer status;

    /**
     * 消息点击动作标示
     * 0-默认
     * 1-立即购买
     * 2-推荐分享
     * 3-打开网页
     */
    @JsonIgnore
    private String actionFlag;

    /**
     * 跳转网页的地址
     * 只有actionFlag为3时才会有
     */
    @JsonIgnore
    private String linkUrl;
}
